/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package evidence.model.modeloveTridy;

import java.io.Serializable;
import java.util.Collections;
import java.util.HashSet;
import java.util.Set;

/**
 *
 * @author Protheo
 */
public class Ukon implements Serializable{
    public static final long serialVersionUID = 1;
    private Set<Integer> klienti;
    private final String jmeno;
    private Set<Integer> typ;

    public Ukon(String jmeno) {
        this.jmeno = jmeno;
        this.klienti = new HashSet<Integer>();
        this.typ = new HashSet<Integer>();
    }

    public void addKlient(int klient) {
        this.klienti.add(klient);
    }

    public void setTyp(int typ) {
        this.typ.add(typ);
    }

    public String getJmeno() {
        return jmeno;
    }

    public Set<Integer> getKlienti() {
        return Collections.unmodifiableSet(klienti);
    }

    public Set<Integer> getTyp() {
        return Collections.unmodifiableSet(typ);
    }

    @Override
    public String toString() {
        return "Ukon{" + "klienti=" + klienti + " jmeno=" + jmeno + " typ=" + typ + '}';
    }
}
